﻿#light

module Cecil

open Mono.Cecil

/// shows help
let showHelp = 0

let procMethod (m: MethodDefinition) = 
    let wrapper1 = MethodDefinition(m.Name, MethodAttributes.Public, m.ReturnType.ReturnType)
    //wrapper1.Parameters.Add(ParameterDefinition("", 1, ParameterAttributes.None, TypeReference
    ()

let procType (t: TypeDefinition) =
    t.Methods |> Seq.cast |> Seq.iter procMethod

/// Processes assemblies
let proc (a: string) =
    let asm = AssemblyFactory.GetAssembly a
    asm.MainModule.Types |> Seq.cast |> Seq.iter procType
    //let outasm = AssemblyFactory.DefineAssembly ("ff", AssemblyKind.Dll)
    //let amodule = ModuleDefinition("", outasm)
    
    ()